// import { getTotalIncome, value } from './incomesSlice'
import { getTotalIncome } from './incomesSlice'
import { getTotalExpense } from './expensesSlice'
import { createSelector } from '@reduxjs/toolkit'

// console.log('测试看到的数据', value.getInitialState())
export const getBalance = createSelector(
  [getTotalIncome, getTotalExpense],
  (totalIncome, totalExpense) => totalIncome - totalExpense
)
